Database schema upgrade as a service

ABSTRACT

A method for upgrading a database schema in real time, wherein the database schema is associated with a plurality of databases is provided. The method may include installing a first plugin on a database upgrade process associated with a database. The method may include installing a second plugin on each database instance within the plurality of databases. The method may include determining a delta associated with a final target version of the database schema. Additionally, the method may include outlining an existence of an incongruence, an existence of an override or an existence of a customization removal based on the determined delta. The method may include performing a peer-to-peer broadcasting analysis between each database. The method may include defining a migration strategy for each database instance within the plurality of databases based on the peer-to-peer broadcasting analysis. The method may further include creating a script for upgrading the database schema.

FIELD OF THE INVENTION

The present invention relates generally to the field of computing, andmore particularly to database schemas.

BACKGROUND

A database schema of a database system is the database's structuredescribed in a formal language supported by the database managementsystem (DBMS). The database schema refers to the organization of data asa blueprint of how a database is constructed. A database schema is a setof formulas (sentences) often referred to as integrity constraintsimposed on a database. These integrity constraints may ensurecompatibility between parts of the schema. All constraints areexpressible in the same language. When a developer develops a softwareusing a database, several versions of the database schema may existeither during the development life cycle of the database as well as whenthe database is in production in a customer environment.

SUMMARY

According to one embodiment, a method for upgrading a database schema inreal time, wherein the database schema is associated with a plurality ofdatabases is provided. The method may include installing a first pluginon a database upgrade process associated with a database. The method mayalso include installing a second plugin on each database instance withinthe plurality of databases. The method may further include determining,by the first plugin, a delta associated with a final target version ofthe database schema. Additionally, the method may include outlining, bythe second plugin, an existence of an incongruence, an existence of anoverride or an existence of a customization removal based on thedetermined delta. The method may also include performing, by the secondplugin, a peer-to-peer broadcasting analysis between each databaseinstance within the plurality of databases based on the outlining. Themethod may include defining, by the first plugin, a migration strategyfor each database instance within the plurality of databases based onthe peer-to-peer broadcasting analysis. The method may further includecreating, by the first plugin, a script for upgrading the databaseschema on each database instance within the plurality of databases basedon the defined migration.

According to another embodiment, a computer system for upgrading adatabase schema in real time, wherein the database schema is associatedwith a plurality of databases is provided. The computer system mayinclude one or more processors, one or more computer-readable memories,one or more computer-readable tangible storage medium, and programinstructions stored on at least one of the one or more tangible storagemedium for execution by at least one of the one or more processors viaat least one of the one or more memories, wherein the computer system iscapable of performing a method. The method may include installing afirst plugin on a database upgrade process associated with a database.The method may also include installing a second plugin on each databaseinstance within the plurality of databases. The method may furtherinclude determining, by the first plugin, a delta associated with afinal target version of the database schema. Additionally, the methodmay include outlining, by the second plugin, an existence of anincongruence, an existence of an override or an existence of acustomization removal based on the determined delta. The method may alsoinclude performing, by the second plugin, a peer-to-peer broadcastinganalysis between each database instance within the plurality ofdatabases based on the outlining. The method may include defining, bythe first plugin, a migration strategy for each database instance withinthe plurality of databases based on the peer-to-peer broadcastinganalysis. The method may further include creating, by the first plugin,a script for upgrading the database schema on each database instancewithin the plurality of databases based on the defined migration.

According to yet another embodiment, a computer program product forupgrading a database schema in real time, wherein the database schema isassociated with a plurality of databases is provided. The computerprogram product may include one or more computer-readable tangiblestorage medium and program instructions stored on at least one of theone or more tangible storage medium, the program instructions executableby a processor. The computer program product may include programinstructions to install a first plugin on a database upgrade processassociated with a database. The computer program product may alsoinclude program instructions to install a second plugin on each databaseinstance within the plurality of databases. The computer program productmay further include program instructions to determine, by the firstplugin, a delta associated with a final target version of the databaseschema. Additionally, the computer program product may include programinstructions to outline, by the second plugin, an existence of anincongruence, an existence of an override or an existence of acustomization removal based on the determined delta. The computerprogram product may also include program instructions to perform, by thesecond plugin, a peer-to-peer broadcasting analysis between eachdatabase instance within the plurality of databases based on theoutlining. The program instructions may include program instructions todefine, by the first plugin, a migration strategy for each databaseinstance within the plurality of databases based on the peer-to-peerbroadcasting analysis. The computer program product may further includeprogram instructions to create, by the first plugin, a script forupgrading the database schema on each database instance within theplurality of databases based on the defined migration.

BRIEF DESCRIPTION OF THE SEVERAL VIEWS OF THE DRAWINGS

These and other objects, features and advantages of the presentinvention will become apparent from the following detailed descriptionof illustrative embodiments thereof, which is to be read in connectionwith the accompanying drawings. The various features of the drawings arenot to scale as the illustrations are for clarity in facilitating oneskilled in the art in understanding the invention in conjunction withthe detailed description. In the drawings:

FIG. 1 illustrates a networked computer environment according to atleast one embodiment;

FIG. 2 illustrates a networked computer environment with a schemaupgrade strategy according to at least one embodiment;

FIG. 3 is an operational flowchart illustrating the steps carried out bya program to upgrade a database schema according to at least oneembodiment; and

FIG. 4 is a block diagram of internal and external components ofcomputers and servers depicted in FIG. 1 according to at least oneembodiment.

DETAILED DESCRIPTION

Detailed embodiments of the claimed structures and methods are disclosedherein; however, it can be understood that the disclosed embodiments aremerely illustrative of the claimed structures and methods that may beembodied in various forms. This invention may, however, be embodied inmany different forms and should not be construed as limited to theexemplary embodiments set forth herein. Rather, these exemplaryembodiments are provided so that this disclosure will be thorough andcomplete and will fully convey the scope of this invention to thoseskilled in the art. In the description, details of well-known featuresand techniques may be omitted to avoid unnecessarily obscuring thepresented embodiments.

Embodiments of the present invention relate to the field of computing,and more particularly to database schemas. The following describedexemplary embodiments provide a system, method and program product to,among other things, provide a service for upgrading a database schema.

As previously described, when a developer develops a software using adatabase, several versions of the database schema may exist eitherduring the development life cycle of the database as well as when thedatabase is in production in a customer environment. Furthermore, whenthe database must be migrated to a new version due to a new build or anew production release, it may become difficult to manage all of thesystem peculiarities while being able to successfully upgrade thedatabase. A common solution to such a problem may be to develop a set ofscripts that has the capability to transform the starting schema into anew schema. However, such a mechanism often fails since thecustomization for each instance of the database may take a long time.Additionally, in the context of software being utilized as a service,the customization issues may become even larger since the volume of thedatabase may be quite large for a single product. Therefore, it may beadvantageous, among other things, to provide a dynamic, resilient, andflexible upgrade system strategy.

According to at least one embodiment, the database schema may beupgraded based on a real time schema validation and introspection tocreate a final script without failure rather than based on a staticcreation of upgrade scripts that depend on the specific starting pointsthat may fail. Furthermore, according to one implementation, the presentembodiment may be iterative so that according to a defined policy (e.g.,add, modify, delete) or according to a role of the operator so that thegoals may be achieved in a segmented way via multiple independent steps.Additionally, consistency rules may be added so that based on specifiedparameters, multiple databases may converge to a common schema ormaintain the schema's peculiarities.

According to at least one implementation of the present embodiment, aplugin may be installed on a database that may be responsible forinteraction between multiple databases in the same site, customer regionor any defined group. The plugin may act differently according to theversion control system that is client-server based since the mainbehavior of the present embodiment is client-client. Additionally, theplugin may provide the capability to define either some default, such as‘when an index is removed from a table, keep it in the upgrade if otherdatabase instances have the same index’; however the plugin may alsohave the capability to define variable based rules (e.g., same group,same network, etc.) or trusted groups to use for the decision.Furthermore, the plugin may also be able (differently from thetraditional ‘version control system’ that may statically decide or notdecide code merging of code) to be adaptive toward the changes and builditself an upgrade strategy by site or by database role. The adaptationmay also be dynamically adjusted based on performance statistics or realtime data since the upgrade strategy may be live, operating in real timeand able to respond to changes in the external conditions when aspecific choice is triggered.

The present invention may be a system, a method, and/or a computerprogram product. The computer program product may include a computerreadable storage medium (or media) having computer readable programinstructions thereon for causing a processor to carry out aspects of thepresent invention.

The computer readable storage medium can be a tangible device that canretain and store instructions for use by an instruction executiondevice. The computer readable storage medium may be, for example, but isnot limited to, an electronic storage device, a magnetic storage device,an optical storage device, an electromagnetic storage device, asemiconductor storage device, or any suitable combination of theforegoing. A non-exhaustive list of more specific examples of thecomputer readable storage medium includes the following: a portablecomputer diskette, a hard disk, a random access memory (RAM), aread-only memory (ROM), an erasable programmable read-only memory (EPROMor Flash memory), a static random access memory (SRAM), a portablecompact disc read-only memory (CD-ROM), a digital versatile disk (DVD),a memory stick, a floppy disk, a mechanically encoded device such aspunch-cards or raised structures in a groove having instructionsrecorded thereon, and any suitable combination of the foregoing. Acomputer readable storage medium, as used herein, is not to be construedas being transitory signals per se, such as radio waves or other freelypropagating electromagnetic waves, electromagnetic waves propagatingthrough a waveguide or other transmission media (e.g., light pulsespassing through a fiber-optic cable), or electrical signals transmittedthrough a wire.

Computer readable program instructions described herein can bedownloaded to respective computing/processing devices from a computerreadable storage medium or to an external computer or external storagedevice via a network, for example, the Internet, a local area network, awide area network and/or a wireless network. The network may comprisecopper transmission cables, optical transmission fibers, wirelesstransmission, routers, firewalls, switches, gateway computers and/oredge servers. A network adapter card or network interface in eachcomputing/processing device receives computer readable programinstructions from the network and forwards the computer readable programinstructions for storage in a computer readable storage medium withinthe respective computing/processing device.

Computer readable program instructions for carrying out operations ofthe present invention may be assembler instructions,instruction-set-architecture (ISA) instructions, machine instructions,machine dependent instructions, microcode, firmware instructions,state-setting data, or either source code or object code written in anycombination of one or more programming languages, including an objectoriented programming language such as Smalltalk, C++ or the like, andconventional procedural programming languages, such as the “C”programming language or similar programming languages. The computerreadable program instructions may execute entirely on the user'scomputer, partly on the user's computer, as a stand-alone softwarepackage, partly on the user's computer and partly on a remote computeror entirely on the remote computer or server. In the latter scenario,the remote computer may be connected to the user's computer through anytype of network, including a local area network (LAN) or a wide areanetwork (WAN), or the connection may be made to an external computer(for example, through the Internet using an Internet Service Provider).In some embodiments, electronic circuitry including, for example,programmable logic circuitry, field-programmable gate arrays (FPGA), orprogrammable logic arrays (PLA) may execute the computer readableprogram instructions by utilizing state information of the computerreadable program instructions to personalize the electronic circuitry,in order to perform aspects of the present invention.

Aspects of the present invention are described herein with reference toflowchart illustrations and/or block diagrams of methods, apparatus(systems), and computer program products according to embodiments of theinvention. It will be understood that each block of the flowchartillustrations and/or block diagrams, and combinations of blocks in theflowchart illustrations and/or block diagrams, can be implemented bycomputer readable program instructions.

These computer readable program instructions may be provided to aprocessor of a general purpose computer, special purpose computer, orother programmable data processing apparatus to produce a machine, suchthat the instructions, which execute via the processor of the computeror other programmable data processing apparatus, create means forimplementing the functions/acts specified in the flowchart and/or blockdiagram block or blocks. These computer readable program instructionsmay also be stored in a computer readable storage medium that can directa computer, a programmable data processing apparatus, and/or otherdevices to function in a particular manner, such that the computerreadable storage medium having instructions stored therein comprises anarticle of manufacture including instructions which implement aspects ofthe function/act specified in the flowchart and/or block diagram blockor blocks.

The computer readable program instructions may also be loaded onto acomputer, other programmable data processing apparatus, or other deviceto cause a series of operational steps to be performed on the computer,other programmable apparatus or other device to produce a computerimplemented process, such that the instructions which execute on thecomputer, other programmable apparatus, or other device implement thefunctions/acts specified in the flowchart and/or block diagram block orblocks.

The flowchart and block diagrams in the Figures illustrate thearchitecture, functionality, and operation of possible implementationsof systems, methods, and computer program products according to variousembodiments of the present invention. In this regard, each block in theflowchart or block diagrams may represent a module, segment, or portionof instructions, which comprises one or more executable instructions forimplementing the specified logical function(s). In some alternativeimplementations, the functions noted in the block may occur out of theorder noted in the figures. For example, two blocks shown in successionmay, in fact, be executed substantially concurrently, or the blocks maysometimes be executed in the reverse order, depending upon thefunctionality involved. It will also be noted that each block of theblock diagrams and/or flowchart illustration, and combinations of blocksin the block diagrams and/or flowchart illustration, can be implementedby special purpose hardware-based systems that perform the specifiedfunctions or acts or carry out combinations of special purpose hardwareand computer instructions.

The following described exemplary embodiments provide a system, methodand program product to provide a service for upgrading a databaseschema. According to at least one implementation, the present embodimentis based on a database plugin that may provide either the interfaces tobe contacted by an installer program or the interfaces to cooperate withother database instances. Moreover, the specific plugin may also host aset of behavior profiles ‘instrumenting’ the upgrade process about thedefault choices. An example of an instruction in the profile may be,‘when an index is removed from a table, keep it in the upgrade if otherdatabase instances have the same index’. When the plugin runs, it may beable to retrieve all the information about the target version of thedatabase schema and storing the information in XML files, separating,for more selective use, the information about tables, constraints,indexes, sequences, views and grants for every database's schema.According to this approach, the schema migration may be consolidated inmultiple steps that may be executed according to an iterative approach.Furthermore, when changes have to be applied, in order to upgrade an olddatabase schema version, the plugin may compare the schema objects withthe target ones outlining the differences and automatically creating theSQL statements that are needed to bring the database to the expected newversion.

For example, if the NOT NULL constraint on the column C1 of the tableS.T1 is added in the new version of the database, automatically thesecond application may generate the following SQL statements:

  ALTER TABLE S.T1 ALTER COLUMN C1 SET NOT NULL ; REORG TABLE S.T1 ALLOWREAD ACCESS ;

-   -   As a second step (2), other instances of the databases (same        network, same distributed installation, or whatever custom        defined rule) may be queried to create a complete upgrade plan        and build a consolidated decision strategy on the single        instance.    -   The third step (3) in case of the source not having consistency        with the expected schema: the present embodiment may gain access        to database statistic to automatically build a decision on the        upgrade. For example, when a table or an index is found in the        source database and it is not present on the target database,        the plugin may either access the database statistic and/or query        other databases on the network to understand if it is used and        must be maintained in the new one.    -   The last step (4) may be comparing the needed authorization for        each SQL statement and grouping steps according to the required        roles. For example, a group of instructions to be executed by a        standard user and another group of instructions to be executed        for an administrator.    -   The decisions of steps 2, 3 and 4 (above) may be defined by the        profile, prompted to the user or any combination of the two        approaches.

Referring now to FIG. 1, an exemplary networked computer environment 100in accordance with one embodiment is depicted. The networked computerenvironment 100 may include a computer 102 with a processor 104 and adata storage device 106 that is enabled to run a Database Schema UpgradeProgram 108A. The networked computer environment 100 may also include aserver 112 that is enabled to run a Database Schema Upgrade Program 108Band a communication network 110. The server 112 may also include adatabase 114. The networked computer environment 100 may include aplurality of computers 102 and servers 112, only one of which is shownfor illustrative brevity. The communication network may include varioustypes of communication networks, such as a wide area network (WAN),local area network (LAN), a telecommunication network, a wirelessnetwork, a public switched network and/or a satellite network. It may beappreciated that FIG. 1 provides only an illustration of oneimplementation and does not imply any limitations with regard to theenvironments in which different embodiments may be implemented. Manymodifications to the depicted environments may be made based on designand implementation requirements.

The client computer 102 may communicate with server computer 112 via thecommunications network 110. The communications network 110 may includeconnections, such as wire, wireless communication links, or fiber opticcables. As will be discussed with reference to FIG. 4, server computer112 may include internal components 800 a and external components 900 a,respectively and client computer 102 may include internal components 800b and external components 900 b, respectively. Client computer 102 maybe, for example, a mobile device, a telephone, a personal digitalassistant, a netbook, a laptop computer, a tablet computer, a desktopcomputer, or any type of computing device capable of running a programand accessing a network.

A program, such as a Database Schema Upgrade Program 108A and 108B mayrun on the client computer 102 or on the server computer 112. TheDatabase Schema Upgrade Program 108A, 108B may provide a service forupgrading a database schema. According to at least one implementation ofthe present embodiment, the Database Schema Upgrade Program 108A, 108Bmay be implemented as a plugin and may be installed on a database thatmay be responsible for interaction between multiple databases in thesame site, customer region or any defined group. The Database SchemaUpgrade method is explained in further detail below with respect to FIG.3.

Referring now to FIG. 2, a networked computer environment 200 with aschema upgrade strategy 204 in accordance with one embodiment isdepicted. According to at least one implementation, the presentembodiment may include an upgrade process 202. The upgrade process 202may be the traditional installer package with associated a relationaldatabase management system (RDMS). For example, with respect to FIG. 2,the RDMS is indicated as version 4 of a database 222. According to oneimplementation, the upgrade process may also include a process plugincomponent 214 (i.e., a first plugin) of the Database Schema UpgradeProgram 108A, 108B (FIG. 1) that may be able to interact with otherplugin components 206-212 (i.e., a second plugin) of the Database SchemaUpgrade Program 108A, 108B (FIG. 1).

The Database Schema Upgrade Program 108A, 108B (FIG. 1) is depicted ashaving the process plugin component 214 with respect to FIG. 2 which mayprovide either the interfaces to be contacted by an installer program orthe interfaces to cooperate with other database instances such as“Customer 1” 216, “Customer 2” 218 and “Customer N” 220. Moreover, thespecific process plugin 214 may also host a set of behavior profiles‘instrumenting’ the upgrade process about the default choices. Anexample of such an instruction into the profile may be ‘when an index isremoved from a table, keep it in the upgrade if other database instanceshave the same index’.

According to one implementation, the Database Schema Upgrade Program108A, 108B (FIG. 1) may include a first and a second plugin forupgrading a database schema in real time, where the database schema isassociated with a plurality of databases. The first plugin may beimplemented as part of the upgrade process 202 associated with adatabase 222. The second plugin may be installed as a plugin 206-212 oneach database instance. The first plugin 214 may determine a deltaassociated with a final target version of the database schema. Then, thesecond plugin 206-212 may outline an existence of an incongruence, anexistence of an override or an existence of a customization removalbased on the determined delta. Next, the second plugin 206-212 mayperform a peer-to-peer broadcasting analysis between each databaseinstance within the plurality of databases based on the outlining. Thefirst plugin 214 may then define a migration strategy for each databaseinstance within the plurality of databases based on the peer-to-peerbroadcasting analysis. Then, the first plugin 214 may create a scriptfor upgrading the database schema on each database instance within theplurality of databases based on the defined migration.

FIG. 3, an operational flowchart 300 illustrating the steps carried outby a program upgrade a database schema in accordance with one embodimentis depicted. According to the present embodiment, the Database SchemaUpgrade Program 108A, 108B (FIG. 1) may be implemented as a first plugin214 (FIG. 2) that may be installed as part of the upgrade process 202(FIG. 2) on a database 222 (FIG. 2) that may be responsible forinteraction between multiple databases with their respective plugins206-212 (i.e., a second plugin) in the same site, customer region or anydefined group. The Database Schema Upgrade Program 108A, 108B (FIG. 1)(i.e., the process plugin 214 (FIG. 2) and the corresponding plugins206-212 (FIG. 2) on each database instance) may provide the capabilityto define either some default or variable based rules (e.g., same group,same network, etc.) or trusted groups to use for the decision.Furthermore, the plugin 214 along with the corresponding plugins on eachdatabase instance 206-212 (FIG. 2) may also be able to be adaptivetoward the changes and build itself an upgrade strategy by site or bydatabase role. The adaptation may also be dynamically adjusted based onperformance statistic or real time data.

Referring now to FIG. 3 at 302, a final target state (e.g., the upgradedcode) is defined by the upgrade process plugin component 214 (FIG. 2)and the final target state is compared with the existing code. As such,the final state of database is compared with the existing databaseschema to determine whether the expected database version (n−1) needs tobe customized or changed during that time.

Next at 304, the determined delta is identified by the upgrade processplugin component 214 (FIG. 2). Therefore, the determined delta betweenthe target version of the database and the current version of thedatabase is identified. Then at 306, the incongruences, override, andcustomization removal are outlined by the database plugins 206-212 (FIG.2) associated with each instance of the database. For example, anyincongruence (i.e., difference) between the expected schema and apossible override of the local customization may be outlined.

Next at 308, peer-to-peer broadcasting analysis is performed by thedatabase plugins 206-212 (FIG. 2) associated with each instance of thedatabase to gather data related conflicts. As such, each plugin 206-212(FIG. 2) associated with each instance of the database may broadcast arequest to other peers (i.e., other database plugins 206-212) (FIG. 2)in order to gather information about conflicts. For example, “mydatabase version has an index of the table removed, what about yourversion”?

Then at 310, group analysis (regional based, LAN based, affinity based)may be gathered by the database plugins 206-212 (FIG. 2) associated witheach instance of the database for optimization. As such, the previousanalysis may be profiled according to the specific configuration. Forexample, a request may be restricted or a greater weight may be given todatabase instances of the same network, same vendor, same customer type,such as banking customers, etc.

Next at 312, decomposition of change set based on roles may be performedby the database plugins 206-212 (FIG. 2) associated with each instanceof the database. Therefore, the changes to be applied are decomposed byroles once they are identified. For example, a change may be identifiedas requiring the role of Administrative right, while another change maybe identified as having a standard user right.

Then at 314, the migration strategy may be defined identifying thenumber of migration phases and roles associated. As such, the upgradestrategy may be defined by the database plugins 206-212 (FIG. 2)associated with each instance of the database with the number of stepsand the roles associated with the steps (e.g., 3 steps by Admin and 2 bystandard user).

Next, at 316, the first phase of migration may be performed by thedatabase plugins 206-212 (FIG. 2) associated with each instance of thedatabase with optional iteration of previous steps 308-312. Therefore,the previous steps of 308-312 may be performed in an iterative way.

Then at 318, a set of changes may be implemented by the database plugins206-212 (FIG. 2) associated with each instance of the database in aconfigurable way or in trial mode with local or third party verificationand available rollback. As such, some of the steps may be configured tocomply with specific local rules. For example, Administrator changes mayhappen in specific timeframes or some set of changes, such as tabledropping may happen in a sort of trial mode that may delete the tables,monitor for a specific timeframe (optionally check or compareperformance with peers) and then decide to commit or rollback changes.

Next at 320, statistical data may be used by the database plugins206-212 (FIG. 2) associated with each instance of the database toconfirm, rollback or simply isolate one of conflicts of step 306. Forexample, some steps may be validated by statistical data, such as anindex in a table guaranteed a performance improvement in which case theplugin may decide not to remove the conflict.

Then at 322, once the upgrade strategy is built and/or executed by theupgrade process plugin component 214 (FIG. 2), a policy based approachmay promote the strategy to replace the target state of step 302. Forexample, the upgrade strategy may replace the original target state andor associate the target with a specific policy (e.g., performanceoptimization, banking customers, etc.).

Next at 324, the new target state may optionally be differentlyinstantiated by the upgrade process plugin component 214 (FIG. 2) in aparametric way. For example, the final state for a database local toregion1 with network xxx is target1. As such, the new target may beinstantiated in a parametric way so that when the new target is appliedto a specific database instance, one or more policies may be used andthe relative target may be applied.

It may be appreciated that FIG. 3 provides only an illustration of oneimplementation and does not imply any limitations with regard to howdifferent embodiments may be implemented. Many modifications to thedepicted environments may be made based on design and implementationrequirements. For example, according to one implementation, the databaseplugin component associated with each instance of the database 206-212(FIG. 2) may be responsible for steps 306-320 previously described abovewith respect to FIG. 3 and the upgrade process component (i.e., processplugin) 214 (FIG. 2) may be responsible for steps 302-304 and steps322-324 previously described above with respect to FIG. 3.

The present embodiment may have the capability to successfully upgrade adatabase schema despite the peculiarities of the database and therefore,may be significant in distributed environments, such as a databaseschema that may be related to a software as a service solution wherethere is no prefixed starting schema. Also, the present embodiment mayhave advantages in terms of code maintenance since there may not be theneed to maintain different versions of code associated with differentversions of schemas. Furthermore, another advantage may be the built incapability to allow multiple role like standard operators oradministrative operators to concur to the upgrade at different timesaccording to an iterative approach. Additionally, the present embodimentmay be able to consolidate schemas based on information matching andcomputation between multiple instances of the database.

FIG. 4 is a block diagram 400 of internal and external components ofcomputers depicted in FIG. 1 in accordance with an illustrativeembodiment of the present invention. It should be appreciated that FIG.4 provides only an illustration of one implementation and does not implyany limitations with regard to the environments in which differentembodiments may be implemented. Many modifications to the depictedenvironments may be made based on design and implementationrequirements.

Data processing system 800, 900 is representative of any electronicdevice capable of executing machine-readable program instructions. Dataprocessing system 800, 900 may be representative of a smart phone, acomputer system, PDA, or other electronic devices. Examples of computingsystems, environments, and/or configurations that may represented bydata processing system 800, 900 include, but are not limited to,personal computer systems, server computer systems, thin clients, thickclients, hand-held or laptop devices, multiprocessor systems,microprocessor-based systems, network PCs, minicomputer systems, anddistributed cloud computing environments that include any of the abovesystems or devices.

User client computer 102 (FIG. 1), and network server 112 (FIG. 1) mayinclude respective sets of internal components 800 a, b and externalcomponents 900 a, b illustrated in FIG. 4. Each of the sets of internalcomponents 800 a, b includes one or more processors 820, one or morecomputer-readable RAMs 822 and one or more computer-readable ROMs 824 onone or more buses 826, and one or more operating systems 828 and one ormore computer-readable tangible storage devices 830. The one or moreoperating systems 828 and Database Schema Upgrade Program108A (FIG. 1)in client computer 102 (FIG. 1) and Database Schema Upgrade Program108B(FIG. 1) in network server computer 112 (FIG. 1) are stored on one ormore of the respective computer-readable tangible storage devices 830for execution by one or more of the respective processors 820 via one ormore of the respective RAMs 822 (which typically include cache memory).In the embodiment illustrated in FIG. 4, each of the computer-readabletangible storage devices 830 is a magnetic disk storage device of aninternal hard drive. Alternatively, each of the computer-readabletangible storage devices 830 is a semiconductor storage device such asROM 824, EPROM, flash memory or any other computer-readable tangiblestorage device that can store a computer program and digitalinformation.

Each set of internal components 800 a, b, also includes a R/W drive orinterface 832 to read from and write to one or more portablecomputer-readable tangible storage devices 936 such as a CD-ROM, DVD,memory stick, magnetic tape, magnetic disk, optical disk orsemiconductor storage device. A software program, such as DatabaseSchema Upgrade Program 108A (FIG. 1) and 108B (FIG. 1), can be stored onone or more of the respective portable computer-readable tangiblestorage devices 936, read via the respective R/W drive or interface 832and loaded into the respective hard drive 830.

Each set of internal components 800 a, b also includes network adaptersor interfaces 836 such as a TCP/IP adapter cards, wireless Wi-Fiinterface cards, or 3G or 4G wireless interface cards or other wired orwireless communication links. The Database Schema Upgrade Program 108A(FIG. 1) in client computer 102 (FIG. 1) and Database Schema UpgradeProgram 108B (FIG. 1) in network server 112 (FIG. 1) can be downloadedto client computer 102 (FIG. 1) from an external computer via a network(for example, the Internet, a local area network or other, wide areanetwork) and respective network adapters or interfaces 836. From thenetwork adapters or interfaces 836, the Database Schema Upgrade Program108A (FIG. 1) in client computer 102 (FIG. 1) and the Database SchemaUpgrade Program 108B (FIG. 1) in network server computer 112 (FIG. 1)are loaded into the respective hard drive 830. The network may comprisecopper wires, optical fibers, wireless transmission, routers, firewalls,switches, gateway computers and/or edge servers.

Each of the sets of external components 900 a, b can include a computerdisplay monitor 920, a keyboard 930, and a computer mouse 934. Externalcomponents 900 a, b can also include touch screens, virtual keyboards,touch pads, pointing devices, and other human interface devices. Each ofthe sets of internal components 800 a, b also includes device drivers840 to interface to computer display monitor 920, keyboard 930 andcomputer mouse 934. The device drivers 840, R/W drive or interface 832and network adapter or interface 836 comprise hardware and software(stored in storage device 830 and/or ROM 824).

The descriptions of the various embodiments of the present inventionhave been presented for purposes of illustration, but are not intendedto be exhaustive or limited to the embodiments disclosed. Manymodifications and variations will be apparent to those of ordinary skillin the art without departing from the scope of the describedembodiments. The terminology used herein was chosen to best explain theprinciples of the embodiments, the practical application or technicalimprovement over technologies found in the marketplace, or to enableothers of ordinary skill in the art to understand the embodimentsdisclosed herein.

What is claimed is:
 1. A method for upgrading a database schema in realtime, wherein the database schema is associated with a plurality ofdatabases, the method comprising: installing a first plugin on adatabase upgrade process associated with a database; installing a secondplugin on each database instance within the plurality of databases;determining, by the first plugin, a delta associated with a final targetversion of the database schema; outlining, by the second plugin, anexistence of an incongruence, an existence of an override or anexistence of a customization removal based on the determined delta;performing, by the second plugin, a peer-to-peer broadcasting analysisbetween each database instance within the plurality of databases basedon the outlining; defining, by the first plugin, a migration strategyfor each database instance within the plurality of databases based onthe peer-to-peer broadcasting analysis; creating, by the first plugin, ascript for upgrading the database schema on each database instancewithin the plurality of databases based on the defined migration;upgrading the database schema on each database instance within theplurality of databases based on the created script; and consolidating aplurality of upgraded database schemas based on a plurality ofinformation that matches multiple instances of each database instancewithin the plurality of databases.
 2. The method of claim 1, wherein thefinal target version comprises an upgraded version of the databaseschema.
 3. The method of claim 1, wherein the determined delta comprisesa comparison of the final target version of the database schema with acurrent version of the database schema associated each database instancewithin the plurality of databases.
 4. The method of claim 1, wherein thepeer-to-peer broadcasting analysis comprises at least one of a gatheringof data related to conflicts, a gathering of group analysis data, and agathering of roles associated with the database instance.
 5. The methodof claim 4, wherein a decomposition of a change set is performed basedon the gathering of roles associated with each database instance.
 6. Themethod of claim 1, wherein the defining the migration strategy for eachdatabase instance comprises identifying a plurality of migration phasesrequired and identifying at least one corresponding role associated witheach migration phase within the plurality of migration phases.
 7. Themethod of claim 1, wherein the created script for upgrading the databaseschema on each database instance within the plurality of databases isexecuted automatically on each database instance within the plurality ofdatabases.
 8. A computer system for upgrading a database schema in realtime, wherein the database schema is associated with a plurality ofdatabases, the computer system comprising: one or more processors, oneor more computer-readable memories, one or more computer-readabletangible storage medium, and program instructions stored on at least oneof the one or more tangible storage medium for execution by at least oneof the one or more processors via at least one of the one or morememories, wherein the computer system is capable of performing a methodcomprising: installing a first plugin on a database upgrade processassociated with a database; installing a second plugin on each databaseinstance within the plurality of databases; determining, by the firstplugin, a delta associated with a final target version of the databaseschema; outlining, by the second plugin, an existence of anincongruence, an existence of an override or an existence of acustomization removal based on the determined delta; performing, by thesecond plugin, a peer-to-peer broadcasting analysis between eachdatabase instance within the plurality of databases based on theoutlining; and defining, by the first plugin, a migration strategy foreach database instance within the plurality of databases based on thepeer-to-peer broadcasting analysis; creating, by the first plugin, ascript for upgrading the database schema on each database instancewithin the plurality of databases based on the defined migration;upgrading the database schema on each database instance within theplurality of databases based on the created script; and consolidating aplurality of upgraded database schemas based on a plurality ofinformation that matches multiple instances of each database instancewithin the plurality of databases.
 9. The computer system of claim 8,wherein the final target version comprises an upgraded version of thedatabase schema.
 10. The computer system of claim 8, wherein thedetermined delta comprises a comparison of the final target version ofthe database schema with a current version of the database schemaassociated each database instance within the plurality of databases. 11.The computer system of claim 8, wherein the peer-to-peer broadcastinganalysis comprises at least one of a gathering of data related toconflicts, a gathering of group analysis data, and a gathering of rolesassociated with the database instance.
 12. The computer system of claim11, wherein a decomposition of a change set is performed based on thegathering of roles associated with each database instance.
 13. Thecomputer system of claim 8, wherein the defining the migration strategyfor each database instance comprises identifying a plurality ofmigration phases required and identifying at least one correspondingrole associated with each migration phase within the plurality ofmigration phases.
 14. The computer system of claim 8, wherein thecreated script for upgrading the database schema on each databaseinstance within the plurality of databases is executed automatically oneach database instance within the plurality of databases.
 15. A computerprogram product for upgrading a database schema in real time, whereinthe database schema is associated with a plurality of databases, thecomputer program product comprising: one or more computer-readabletangible storage medium and program instructions stored on at least oneof the one or more tangible storage medium, the program instructionsexecutable by a processor, the program instructions comprising: programinstructions to install a first plugin on a database upgrade processassociated with a database; program instructions to install a secondplugin on each database instance within the plurality of databases;program instructions to determine, by the first plugin, a deltaassociated with a final target version of the database schema; programinstructions to outline, by the second plugin, an existence of anincongruence, an existence of an override or an existence of acustomization removal based on the determined delta; programinstructions to perform, by the second plugin, a peer-to-peerbroadcasting analysis between each database instance within theplurality of databases based on the outlining; and program instructionsto define, by the first plugin, a migration strategy for each databaseinstance within the plurality of databases based on the peer-to-peerbroadcasting analysis; program instructions to create, by the firstplugin, a script for upgrading the database schema on each databaseinstance within the plurality of databases based on the definedmigration; program instructions to upgrade the database schema on eachdatabase instance within the plurality of databases based on the createdscript; and program instructions to consolidate a plurality of upgradeddatabase schemas based on a plurality of information that matchesmultiple instances of each database instance within the plurality ofdatabases.
 16. The computer program product of claim 15, wherein thefinal target version comprises an upgraded version of the databaseschema.
 17. The computer program product of claim 15, wherein thedetermined delta comprises a comparison of the final target version ofthe database schema with a current version of the database schemaassociated each database instance within the plurality of databases. 18.The computer program product of claim 15, wherein the peer-to-peerbroadcasting analysis comprises at least one of a gathering of datarelated to conflicts, a gathering of group analysis data, and agathering of roles associated with the database instance.
 19. Thecomputer program product of claim 18, wherein a decomposition of achange set is performed based on the gathering of roles associated witheach database instance.
 20. The computer program product of claim 15,wherein the defining the migration strategy for each database instancecomprises identifying a plurality of migration phases required andidentifying at least one corresponding role associated with eachmigration phase within the plurality of migration phases.